﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Truextend.CoffeShop.Model;
using Truextend.Common.Data;

namespace Truextend.CoffeShop.Business.Tests
{
    public class BaseTestClass
    {
        public void ExecuteManager(Action<IUnitOfWork> coreMethod, Action postCommit=null)
        {
            var uow = new EFUnitOfWork<CoffeShopEntities>();
            uow.Start();
            coreMethod(uow);
            uow.End();
            if (postCommit != null) postCommit();
        }
    }
}
